<?php

function checkLength($str, $min, $max)
{
    preg_match_all('/./u', $str, $matches);
    /*echo '<pre>';
    var_dump($matches[0]);
    echo '</pre>';*/
    $len = count($matches[0]);
    if ($len < $min || $len > $max) {
        return false;
    } else {
        return true;
    }
}


function getNum()
{
    return 10;
}

function check_verify($code, $id = '')
{
    $verify = new \Think\Verify();
    return $verify->check($code, $id);
}

function get_user_id(){
    return rand();
}